const Sequelize = require('sequelize');
module.exports = function(sequelize, DataTypes) {
  return sequelize.define('project_subject', {
    subjectID: {
      type: DataTypes.STRING(50),
      allowNull: false
    },
    subjectName: {
      type: DataTypes.TEXT,
      allowNull: true
    },
    projectTotal: {
      type: DataTypes.INTEGER,
      allowNull: true
    },
    subjectType: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    subjectRegion: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    subjectAddress: {
      type: DataTypes.TEXT,
      allowNull: true
    },
    subjectArea: {
      type: DataTypes.DOUBLE,
      allowNull: true
    },
    subjectCost: {
      type: DataTypes.DOUBLE,
      allowNull: true
    },
    beginDate: {
      type: DataTypes.DATE,
      allowNull: true
    },
    finishDate: {
      type: DataTypes.DATE,
      allowNull: true
    },
    subjectStatus: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    bjDate: {
      type: DataTypes.DATE,
      allowNull: true
    },
    bjMan: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    subjectNum: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    structType: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    subdistrict: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    schedule: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    CreateTime: {
      type: DataTypes.DATE,
      allowNull: true
    },
    UpdateTime: {
      type: DataTypes.DATE,
      allowNull: true
    },
    prjNum: {
      type: DataTypes.TEXT,
      allowNull: true
    },
    prjpwemits_num: {
      type: DataTypes.STRING(100),
      allowNull: true
    }
  }, {
    sequelize,
    tableName: 'project_subject',
    timestamps: false
  });
};
